home *** CD-ROM | disk | FTP | other *** search
- /*
- This Arexxscript gives an example for using ARexx with
- ScanTrax © by Klaus Krause 1997
- */
-
- OPTIONS RESULTS
-
- ADDRESS "SCANTRAX"
-
- say "Short AmigaRexx Demonstration:"
-
- say
- say "Look at the default/current ARexx-picture-setup:"
- GET_INTENSITY
- say " Intensity = " RESULT "%"
- GET_CONTRAST
- say " Contrast = " RESULT "%"
- GET_COLOR_RED
- say " Color Red = " RESULT "%"
- GET_COLOR_GREEN
- say " Color Green = " RESULT "%"
- GET_COLOR_BLUE
- say " Color Blue = " RESULT "%"
- GET_SHARPEN
- say " Sharpen = " RESULT "%"
- GET_GAMMA
- say " Gamma = " RESULT
- say
- say "Load the program-picture-setup into ARexx-picture-setup"
- CUSTOM_PRESET
- say
- say "Now we get the following:"
- GET_INTENSITY
- say " Intensity = " RESULT "%"
- GET_CONTRAST
- say " Contrast = " RESULT "%"
- GET_COLOR_RED
- say " Color Red = " RESULT "%"
- GET_COLOR_GREEN
- say " Color Green = " RESULT "%"
- GET_COLOR_BLUE
- say " Color Blue = " RESULT "%"
- GET_SHARPEN
- say " Sharpen = " RESULT "%"
- GET_GAMMA
- say " Gamma = " RESULT
- say
- say
- say "Now we modifiy the ARexx-picture-setup"
- say " Adjust intensity to 0%"
- SET_INTENSITY '0'
- say " Adjust contrast to 14%"
- SET_CONTRAST '14'
- say " Adjust sharpen to 50%"
- SET_SHARPEN '50'
- say " Adjust gamma to 2.20"
- SET_GAMMA '2.2'
- say
- say "Now we set the window parameters:"
- say " Adjust a 100% Scale in xy direction"
- SET_SCALE 100 100
- say " Adjust ScanResolution to 75 dpi"
- SET_RESOLUTION 75 75
- say " Adjust the graphicsmode to 24Bit Color"
- SET_GFXMODE 6
- say " Adjust autosuffix to ON"
- SET_AUTOSUFFIX 1
- say " Adjust centimeters as input unit"
- SET_MEASUREUNIT 0
- say " Adjust the scanwindow with xy-offset=5cm and xysize=10cm"
- SET_WINDOW 5 5 10 10
- say
- say
- say "Hide the Display"
- DISPLAY_HIDE
- say
- say
- say "Scanning to tempfile...."
- SCAN
- say
- say
- say "Writing a PiNG picture to ram:Testpicture..."
- SAVE_PICTURE 0 'RAM:Testpicture'
- say
- say "Set JPG Quality to 45"
- SET_JPGQUALITY 45
- say "Writing a JPEG picture to ram:Testpicture..."
- SAVE_PICTURE 2 'RAM:Testpicture'
- say
- say "Writing a TARGA picture to ram:Testpicture..."
- SAVE_PICTURE 1 'RAM:Testpicture'
- say
- say "Writing a IFF-DEEP picture to ram:Testpicture..."
- SAVE_PICTURE 3 'RAM:Testpicture'
- say
- say
- say "Switch the Compression to ON"
- SET_COMPRESSION 1
- say "Writing a IFF-ILBM picture to ram:Testpicture..."
- SAVE_PICTURE 4 'RAM:Testpicture'
- say
- say
- say "Show the Display"
- DISPLAY_SHOW
- say "Quit ScanTrax with 'QUIT'"
- say
- say "Looking into the RamDisk:"
- ADDRESS COMMAND "C:list ram:Testpicture#?"
- say
-
-
- EXIT
-